package com.zhang.apidriver.service.impl;

import com.zhang.apidriver.remote.ServiceOrderClient;
import com.zhang.apidriver.service.ApiDriverOrderInfoService;
import com.zhang.internalcommon.constant.IdentityConstant;
import com.zhang.internalcommon.dto.OrderRequest;
import com.zhang.internalcommon.dto.ResponseResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 类功能描述
 *
 * @author Kye
 * @date 2025-04-20
 */
@Service
public class ApiDriverOrderInfoServiceImpl implements ApiDriverOrderInfoService {
	@Autowired
	private ServiceOrderClient serviceOrderClient;

	@Override
	public ResponseResult toPickUpPassenger(OrderRequest orderRequest) {
		return serviceOrderClient.toPickUpPassenger(orderRequest);
	}

	@Override
	public ResponseResult arrivedDeparture(OrderRequest orderRequest) {
		return serviceOrderClient.arrivedDeparture(orderRequest);
	}

	@Override
	public ResponseResult pickUpPassenger(OrderRequest orderRequest) {
		return serviceOrderClient.pickUpPassenger(orderRequest);
	}

	@Override
	public ResponseResult passengerGetoff(OrderRequest orderRequest) {
		return serviceOrderClient.passengerGetoff(orderRequest);
	}

	@Override
	public ResponseResult cancelOrder(Long orderId) {
		return serviceOrderClient.cancel(orderId, IdentityConstant.DRIVER_IDENTITY);
	}
}
